#include <stdio.h>

#include <devices/relay.h>

int
	main(
		void)
{
	struct relaydev *dev;

	dev = relaydev_construct();
	if (dev == NULL) {
		printf("relaydev_construct error\n");
		return -1;
	}

	while (1) {
		int i;	

		for (i = 0; i < 6; i++) {
			relaydev_on(dev, i);
			usleep(1000000);
		}
		usleep(2000000);
		for (i = 0; i < 6; i++) {
			relaydev_off(dev, i);
			usleep(1000000);
		}
		usleep(2000000);
	}

	return 0;
}
